<template>
  <header class="my_header">
    <div class="header_left">{{time}}</div>
    <div class="header_title">{{title}}</div>
    <div class="header_right">author:{{author}}</div>
  </header>
</template>

<script>
  export default {
    name: "header",
    data() {
      return {
        author: '太阳当空丶赵',
        title: '网易云数据驾驶舱',
        time: '2022/10/10 00:00:00'
      }
    },
    mounted(){
      setInterval(()=>{
        let date = new Date();
        this.time = `${date.getFullYear()}/${date.getMonth()+1}/${date.getDate()} ${date.getHours()}:${date.getMinutes()}:${date.getSeconds()}`;
      },1000)
    }
  }
</script>

<style scoped>

</style>
